1. Field of the Invention
The invention relates generally to the field of quality control, in particular to the method and apparatus for calibrating and improving the linearity of a system for scanning moving objects on a production line.
2. Cross References to Related Applications
The present patent application is related to our copending applications, Ser. No. 07/680,306, filed Apr. 4, 1991, and Ser. No. 07/660,542, filed Feb. 25, 1991.
3. Description of Prior Art
Many mass-produced items must be inspected prior to shipment. E.g., beverage bottles must be inspected for flaws prior to filling to prevent breakage in use and consequent lawsuits, injuries, property damage, etc.
Automated inspection machines which analyze images by means of video cameras and computers are known and are used, e.g., for one-step detection of defects in such products as bottles moving on a production line. However, products of more complicated shape, such as screws, required several image inspection steps. In this case, images taken by a video camera are stored in the memory of a computer so that they can be processed for detecting defects. Today industry increasingly demands higher-speed inspection techniques. Some production lines operate with an throughput of 2000 products per minute and with the time interval for inspecting a product as short as 30 milliseconds. Also there is a strong demand that the video images be sharp so as to make it possible to perform efficient defect detection.
In a writing cycle, where a laser beam is used to engrave marks on a product, there is a strong demand for writing sharp marks regardless of high speed movement of the products on the production line.
One type of inspection machine currently used in the market today inspects or engraves prodcuts such as bottles, mounted on a rotary carousel. Such a machine is made by Krones AG., Altestrasse 111, D-5020 Frechen, Germany. Light reflected from each bottle is sent to camera (in a reading cycle), or light is sent from a laser light source to the bottle (in a writing cycle).
In both cases the light beam is guided through a scanning device which controls the accuracy of the beam's movement. In order to provide a sharp image (reading cycle), or sharp marks engraving (writing), the scanning device must possess two important features.
The first feature is linearity, i.e., the ability to cause the light beam to follow a fixed point on a rotating carousel (writing), or to insure that the light reflected from the bottle always comes to an image sensor from a fixed point on the carousel (reading).
The second feature is the requirement of maintaining a fixed optical path. I.e., during rotation of the carousel the optical distance between the light source and the camera (reading), or between the light source on the carousel (writing) should remain constant.
This linear scanning device is shown in FIG. 1 and is described also in the product data of Krones AG. It is essentially a back-and-borth rotating mirror. However it provides insufficiently sharp images when reading, or insufficiently sharp marks when engraving (writing).
The tracking system of FIG. 1 consists of rotating mirror M, which has rotating axis at point (Xm, Ym). Also it uses a rotating carousel 11 having an axis of rotation at point (0,0) which is the origin of coordinates X,Y (not shown). Carousel 11 rotates with an angular velocity .OMEGA..sub.11. Objects, such as bottles 15 to 20, are located on the circumference of a circle centered at (0,0). The objects are distributed uniformly on carousel 11 and rotate therewith. The bottles may also rotate or spin on their own axes (not indicated). The arc between two adjacent objects is related to the center (0,0); it is called a periodic tracking arc.
An incident beam 12 originates at point (X0,Y0) and is directed toward rotating mirror M. Beam 12 is reflected from mirror M as a tracking beam 14 which falls onto an bottle 20 on carousel 11. As mirror M rotates, beam 14 tracks the movement of bottle 20. The final position of mirror M is shown by broken line M'. In the periodic rotation the mirror swings across an angle .beta..sub.M, (beta.sub.M). In that final position, the beam reflected from mirror M is also shown by broken line 14'. To follow bottle 20 to the position of a second bottle 15, one full periodic rotation of mirror M for angle .beta..sub.M reflects the tracking beam at view angle .differential..sub.M (gamma.sub.M). While bottle 20 advances to the position of bottle 15, the latter assumes the position of a third bottle 16. Incident beam 12 remains static.
The basic optical rule for an incident beam and the beam reflected from a mirror M is that periodic mirror rotation angle .beta..sub.M should be half of view angle .differential..sub.M. After tracking bottle 20 over angle .differential..sub.M, mirror M quickly returns to its initial position shown in solid-line form.
The process and apparatus described above involves back-and-forth rotations or oscillations of mirror M over angle .beta..sub.M. Such back-and-forth motions create vibrations, resulting in optical distortions and accelerations that cause deviation from the linear relationship described earlier.
FIG. 2 illustrates another prior-art system. This system consists of a rotating polygon 22, a carousel 24 and rotating mirror M1. The system has two tracking paths: one with a rotating polygon 22 and the second with a rotating mirror M1. Carousel 24, polygon 22, and mirror M1 are mounted on the same axis of rotation.
Point (0,0) is the origin of coordinates X,Y (not shown). Both polygon 22 and mirror M1 rotate with the same angular velocity .OMEGA..sub.10 and therefore have the same angle of rotation. The initial positions of both are shown by solid lines and their final positions by broken lines. An incident beam 26 originates at point (X0,Y0) and crosses the carousel's circumference at point (Xc,Yc). It then hits facet 28 of the polygon at a right angle at point (X5,Y5) and mirror M1 at point (0,0). Then the beam is reflected back along a line (0,0)-(X0,Y0).
Incident beam 26 originates at point (X0,Y0) and crosses the carousel circumference at point (Xc,Yc). The final position of the polygon is shown in broken lines. The beam then hits polygon facet 28 (which now in position 28') at point (X6,Y6) and is reflected as beam 30 that hits the carousel in point (X3,Y3). Beam 26 also hits mirror M1 at point (0,0) and is reflected as beam 32 that hits carousel 24 at point (X4,Y4).
The optical path for the beam that hits and then is reflected from mirror M1 in the initial position of the mirror is twice the distance (Xc,Yc)-(0,0). In the final position of the mirror the optical path is twice the distance (Xc,Yc)-(0,0)-(X4,Y4). In both cases the distance equals twice the carousel's radius (0,0)-(Xc,Yc), i.e., it is a constant value.
An optical law for mirrors states that the angle of reflection from a mirror is equal to the incident angle. So by choosing a gear ratio of 2 to 1 between the carousel and mirror M1 we get a linear tracking movement of mirror M1. The process described above involves back-and-forth rotations of mirror M1 over axis (0,0). Similar to the previously described conventional system, such back-and-forth motion creates vibrations, resulting in optical distortions and accelerations that cause deviations from the linear relationship described earlier.
As far as polygon 22 is concerned, its optical path is equal to distance (Xc,Yc)-(X5,Y5) in the initial position of the polygon, and to (Xc,Yc)-(X3,Y3) in the final position. It is shown clearly in FIG. 2 that the optical path for polygon 22 is not equal to that of mirror M1. It is also clear from FIG. 2 that the polygon's optical path is not a constant value and depends upon the angle of rotation and the radius of polygon 22. The optical path will approach a constant value with a decrease in the polygon's radius r, and when r approaches 0, the polygon's behavior will approach that of a mirror.
This clearly demonstrates that a conventional polygon is not equivalent to a centered mirror, i.e., the conventional polygon does not have a tracking behavior equivalent to centered mirror M1 and also does not have a constant optical path like the mirror does.
Nevertheless, a conventional scanning polygon system seems to be a suitable way to effect periodic tracking using continuous motion scanning so as to replace an oscillating scanning mirror system. Conventional polygons were used in scanning systems to scan targets having distances from the polygon which were much greater than the polygon's radius. Such scanning systems, which are known as a "Forward Looking Infra Red" (FLIR) are described in "The Photonic Design and Application Handbook", 36th edition, P. L. Jacobs, ed. (Laurin Publishing Co., Pittsfield, Mass.)
In the above case, it should be noted that the polygon's nonlinearity as a function of its radius has very little influence upon scanning quality. This means that each facet of the polygon behaves similarly to a flat mirror mounted directly on the rotation axis, ignoring the off-axis effect of the polygon's facets.
However, consider those tracking systems in which the distance of the tracking target from the polygon is not much larger than the polygon's radius. For these it is not justified to treat the polygon's facets as flat mirrors mounted direclty on the rotational axis and to ignore the off-axis effects of the polygon. The designers, however, continued to ignore the polygon's radius in their calculations. With this erroneous design approach, the polygon's radius is chosen arbitrarily, and this results in nonlinear tracking. The use of such a polygon system cannot produce sharp images in reading cycles and results in smearing of the engraved marks in writing cycles. Therefore the system shown in FIG. 2 did not find any practical application.
Also known in the art are tracking systems with tracking in two positions. One such system is described in our above copending application Ser. No. 07/680,306. It is also shown in FIG. 3 in two temporary positions.
The initial position of polygon 34 is shown in solid lines and its second position in broken lines. Bottles 36-41 on a carousel 42 are shown in thick solid lines for the first position and in thin lines for the second position. Polygon 34 and carousel 42 have their axes of rotation at point (0,0), which is the origin of coordinates X,Y. The radii of the carousel and the polygon are R and r, respectively, and their angular velocities are .OMEGA..sub.42 and .OMEGA..sub.34, respectively.
An incident beam 44, in the initial state, originates at point (X0,Y0) and is always static in space. It is reflected from facet 46 (solid line) as a reflected beam 48 (solid line).
In the second position, incident beam 44 is reflected from a facet 46' (broken lines) as beam 48' (broken lines).
The rotation of polygon 34 causes incident beam 44 to follow bottle 36 on the carousel. To have linear tracking, beam 48 must follow bottle 36 along the period tracking arc. The carousel's radius vector follows a fixed point on its circumference, from an initial tracking state (solid line) to the end of the tracking arc, where bottle 37 is now located. (An intermediate state is shown by broken line 48').
As the polygon rotates with time, incident beam 44 hits different facets of polygon 34. The process of tracking is repeated each time another bottle on the carousel is tracked. The tracking angle equals (360/Nc), where Ns is the number of bottles on carousel 42, the polygon's angle of symmetry is .mu. (Mu) and equals (360/Np), where Np is the number of facets on the polygon.
While the polygon rotates an angle equal to .mu., tracking beam 44 is not always following an object on the carousel along an angle equals to .differential. (tracking angle). I.e., rotating the polygon by its symmetry angle does not necessary result in a tracking angle having a size related to the periodic tracking arc.
For systems with an arbitrary relationship between the system's parameters, tracking itself is not always linear, and the beam does not have a constant optical path. Therefore this system does not guarantee reliable linear tracking with an accuracy within a required range.
In our copending application Ser. No. 07/680,306, we describe a system using a conventional polygon which is capable of maintaining linear scanning. This is achieved only under a unique relationship between the radii of the polygon and carousel, i.e., when the radius of the polygon is equal to one-half the tracking radius R divided by the cosine of an angle of 180/n, where n is integer equal to the number of bottles on the carousel.
Although this condition insures linearity, it is valid only for a polygon having a unique set of dimensions. Polygons which are beyond these specified dimensions will not provide linearity. However, there is a demand in the industry for polygons of larger or smaller dimensions, so as to have size flexibility.
However, in reality we can have some allowable deviation from the strictly theoretical linearity within a predetermined range tolerable from the practical point of view. Of course, this tolerable range of deviations will vary, depending upon the type and size of bottles being controlled. For example in a standard carbonated beverage bottle (volume 1.5 L), the allowable deviation will be 0 to 0.1 mm.
The bottles are an example of type of products that can rotate on the carousel for inspection. They can be screws, containers, medicine ampules, and so on.
Nevertheless, it has not been known how to achieve the above objective and to realize a scanning system which has dimensions deviating from the unique relationship between the polygon and the carousel, and which, at the same time, allows deviation from linearity within the desired tolerable range.